﻿using System;
using System.Runtime.Serialization;

namespace OCXS.OCXSServiceLibrary.OPCXMLDA10 {

    [DataContract(Namespace = "http://opcfoundation.org/webservices/XMLDA/1.0/")]
    public class SubscribeRequestItem : System.ComponentModel.INotifyPropertyChanged {

        private string itemPathField;

        private System.Xml.XmlQualifiedName reqTypeField;

        private string itemNameField;

        private string clientItemHandleField;

        private float deadbandField;

        private bool deadbandFieldSpecified;

        private int requestedSamplingRateField;

        private bool requestedSamplingRateFieldSpecified;

        private bool enableBufferingField;

        private bool enableBufferingFieldSpecified;

        [DataMember(Order = 0)]
        public string ItemPath {
            get {
                return this.itemPathField;
            }
            set {
                this.itemPathField = value;
                this.RaisePropertyChanged("ItemPath");
            }
        }

        [DataMember(Order = 1)]
        public System.Xml.XmlQualifiedName ReqType {
            get {
                return this.reqTypeField;
            }
            set {
                this.reqTypeField = value;
                this.RaisePropertyChanged("ReqType");
            }
        }

        [DataMember(Order = 2)]
        public string ItemName {
            get {
                return this.itemNameField;
            }
            set {
                this.itemNameField = value;
                this.RaisePropertyChanged("ItemName");
            }
        }

        [DataMember(Order = 3)]
        public string ClientItemHandle {
            get {
                return this.clientItemHandleField;
            }
            set {
                this.clientItemHandleField = value;
                this.RaisePropertyChanged("ClientItemHandle");
            }
        }

        [DataMember(Order = 4)]
        public float Deadband {
            get {
                return this.deadbandField;
            }
            set {
                this.deadbandField = value;
                this.RaisePropertyChanged("Deadband");
            }
        }

        [DataMember(Order = 5)]
        public bool DeadbandSpecified {
            get {
                return this.deadbandFieldSpecified;
            }
            set {
                this.deadbandFieldSpecified = value;
                this.RaisePropertyChanged("DeadbandSpecified");
            }
        }

        [DataMember(Order = 6)]
        public int RequestedSamplingRate {
            get {
                return this.requestedSamplingRateField;
            }
            set {
                this.requestedSamplingRateField = value;
                this.RaisePropertyChanged("RequestedSamplingRate");
            }
        }

        [DataMember(Order = 7)]
        public bool RequestedSamplingRateSpecified {
            get {
                return this.requestedSamplingRateFieldSpecified;
            }
            set {
                this.requestedSamplingRateFieldSpecified = value;
                this.RaisePropertyChanged("RequestedSamplingRateSpecified");
            }
        }

        [DataMember(Order = 8)]
        public bool EnableBuffering {
            get {
                return this.enableBufferingField;
            }
            set {
                this.enableBufferingField = value;
                this.RaisePropertyChanged("EnableBuffering");
            }
        }

        public bool EnableBufferingSpecified {
            get {
                return this.enableBufferingFieldSpecified;
            }
            set {
                this.enableBufferingFieldSpecified = value;
                this.RaisePropertyChanged("EnableBufferingSpecified");
            }
        }

        public event System.ComponentModel.PropertyChangedEventHandler PropertyChanged;

        protected void RaisePropertyChanged(string propertyName) {
            System.ComponentModel.PropertyChangedEventHandler propertyChanged = this.PropertyChanged;
            if ((propertyChanged != null)) {
                propertyChanged(this, new System.ComponentModel.PropertyChangedEventArgs(propertyName));
            }
        }
    }
}
